//
//  LLT_PlayerModel.m
//  CoderLLT
//
//  Created by 刘晓萌 on 15/12/16.
//  Copyright © 2015年 刘晓萌. All rights reserved.
//

#import "LLT_PlayerModel.h"

@implementation LLT_PlayerModel
-(NSDictionary *)serverDic{
    _serverDic = @{@"艾欧尼亚":@"1",
                                @"祖安":@"3",
                                @"诺克萨斯":@"4",
                                @"班德尔城":@"5",
                                @"皮尔特沃夫":@"7",
                                @"战争学院":@"8",
                                @"巨神峰":@"10",
                                @"雷瑟守备":@"11",
                                @"裁决之地":@"13",
                                @"黑色玫瑰":@"14",
                                @"暗影岛":@"15",
                                @"钢铁烈阳":@"17",
                                @"水晶之痕":@"18",
                                @"均衡教派":@"19",
                                @"影流":@"22",
                                @"守望之海":@"23",
                                @"征服之海":@"24",
                                @"卡拉曼达":@"25",
                                @"皮城警备":@"27",
                                @"比尔吉沃特":@"2",
                                @"德玛西亚":@"6",
                                @"弗雷尔卓德":@"9",
                                @"无畏先锋":@"12",
                                @"恕瑞玛":@"16",
                                @"扭曲丛林":@"20",
                                @"巨龙之巢":@"26",
                                @"教育网专区":@"21"};
    return _serverDic;
}

/**
 * 销毁model
 */
-(void)dealloc{
    
    self.playerIcon = nil;
    self.playerLevel = nil;
    self.playerFC = nil;
    self.serverName = nil;
    self.playerName = nil;
    self.rankClass = nil;
}

-(void)setRankClass:(NSString *)rankClass{
    if (_rankClass != rankClass) {
        _rankClass = nil;
        _rankClass = rankClass;
    }
    _rankClass = [_rankClass stringByReplacingOccurrencesOfString:@"null" withString:@""];
}
-(void)setServerName:(NSString *)serverName{
    if (_serverName != serverName) {
        _serverName = nil;
        _serverName = serverName;
    }
   
    self.serverID = self.serverDic[_serverName];
}
/**
 * KVC赋值失败方法
 */
-(void)setValue:(id)value forUndefinedKey:(NSString *)key{
    
}
@end
